<template>
    <div id="profit">
       <el-tabs type="border-card" @tab-click="handleClick" v-model="activeName">
            <el-tab-pane v-for="item in tabMapOptions" :label="item.label" :key='item.key' :name="item.key"></el-tab-pane>
            <tab-pane :type=type></tab-pane>
            <!-- <el-tab-pane label="日期"></el-tab-pane>
            <el-tab-pane label="游戏"></el-tab-pane>
            <el-tab-pane label="类型"></el-tab-pane>
            <el-tab-pane label="发行商"></el-tab-pane>
            <router-view></router-view> -->
        </el-tabs>
       
    </div>
</template>

<script>
    import tabPane from 'common/tabPane'
    export default {
        data(){
            return{
                tabMapOptions: [
                    { label: '日期', key: 'date' },
                    { label: '游戏', key: 'game' },
                    { label: '类型', key: 'type' },
                    { label: '发行商', key: 'publist' }
                ],
                activeName: 'date',
                type:0,
                date:''
            }
        },
        methods:{
           handleClick(tab) {
                let index=parseInt(tab.index);
                this.type=index;
            }
       
       },
        components:{
            tabPane
        }
    }
</script>

<style scoped>

</style>